package com.scms.secondclass.mapper;

import java.util.List;
import com.scms.secondclass.domain.ActivityEnrollment;

/**
 * 活动报名Mapper接口
 * 
 * @author scms
 */
public interface ActivityEnrollmentMapper 
{
    /**
     * 查询活动报名
     * 
     * @param enrollmentId 活动报名ID
     * @return 活动报名
     */
    public ActivityEnrollment selectActivityEnrollmentByEnrollmentId(Long enrollmentId);

    /**
     * 查询活动报名列表
     * 
     * @param activityEnrollment 活动报名
     * @return 活动报名集合
     */
    public List<ActivityEnrollment> selectActivityEnrollmentList(ActivityEnrollment activityEnrollment);

    /**
     * 查询用户是否已报名活动
     * 
     * @param activityId 活动ID
     * @param userId 用户ID
     * @return 结果
     */
    public int checkUserEnrolled(Long activityId, Long userId);

    /**
     * 查询活动报名人数
     * 
     * @param activityId 活动ID
     * @return 报名人数
     */
    public int countActivityEnrollment(Long activityId);

    /**
     * 新增活动报名
     * 
     * @param activityEnrollment 活动报名
     * @return 结果
     */
    public int insertActivityEnrollment(ActivityEnrollment activityEnrollment);

    /**
     * 修改活动报名
     * 
     * @param activityEnrollment 活动报名
     * @return 结果
     */
    public int updateActivityEnrollment(ActivityEnrollment activityEnrollment);

    /**
     * 更新活动报名状态
     * 
     * @param activityEnrollment 活动报名
     * @return 结果
     */
    public int updateEnrollmentStatus(ActivityEnrollment activityEnrollment);

    /**
     * 更新活动报名签到状态
     * 
     * @param activityEnrollment 活动报名
     * @return 结果
     */
    public int updateEnrollmentSignIn(ActivityEnrollment activityEnrollment);

    /**
     * 删除活动报名
     * 
     * @param enrollmentId 活动报名ID
     * @return 结果
     */
    public int deleteActivityEnrollmentByEnrollmentId(Long enrollmentId);

    /**
     * 批量删除活动报名
     * 
     * @param enrollmentIds 需要删除的数据ID
     * @return 结果
     */
    public int deleteActivityEnrollmentByEnrollmentIds(Long[] enrollmentIds);

    /**
     * 批量签到活动报名
     * 
     * @param enrollmentIds 需要签到的数据ID
     * @param updateBy 更新者
     * @return 结果
     */
    public int batchSignIn(Long[] enrollmentIds, String updateBy);
} 